﻿from utils.serialisator import *

class B:
	def __init__(this):
		this.b = True

class A:
	def __init__(this):
		this.a = 1
		this.s = "abba"
		this.b = B()
		
def main():	#проверка
	a = A()
	s = serialisator(a)
	print s
	a_ = deserialisator(s, {"A": "serialisator_test", "B": "serialisator_test"})
	print ""
	print a.a, a_.a
	print a.s, a_.s
	print a.b.b, a_.b.b

if __name__ == "__main__":
	main()		